<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>网站后台管理系统</title>
<meta name="keywords" content="">
<meta name="description" content="">
<!--[if lte IE 6]>
<link rel="stylesheet" type="text/css" href="css/ie6.css"/>
<![endif]-->
<link rel="stylesheet" type="text/css"  href="../../../../Public/admin/css/style_v2.0.css"/>
<link rel="stylesheet" type="text/css"  href="../../../../Public/layui/css/layui.css">
<link rel="stylesheet" type="text/css"  href="__PUBLIC__/admin/css/style_v2.0.css"/>
<link rel="stylesheet" type="text/css"  href="__PUBLIC__/layui/css/layui.css">
<script type="text/javascript" src="__PUBLIC__/js/jquery-1.8.3.min.js"></script>
<script type="text/javascript" src="__PUBLIC__/layui/layui.js"></script>
</head>
<body>
<div class="position mt10">当前位置：<a href="/admin.php/">后台首页</a> > 分组信息修改</div>
<div id="container">
  <fieldset class="layui-elem-field layui-field-title" style="margin-top: 20px;">
      <legend>分组信息修改</legend>
  </fieldset>
<div class="c"></div> 
<form name=reg action="{:U('Admin/Web/group_update',array('gid' => $data['gid']))}"  enctype="multipart/form-data"  method="post"  class="layui-form" id="group_add">
<div class="layui-form">
    <table class="layui-table">
    <tr>
	  <td width="20%" align="right"><font color=red size="1">·</font>分组名称：</td>
	  <td width="80%">
      <span class="table_span" style="width:300px; float:left;"><input name="groupname" type="text" id="groupname" value="{$data.groupname}" required  lay-verify="" placeholder="分组名称" autocomplete="off" class="layui-input"></span>
      <span class="table_txt"></span>
      </td>
    </tr>
    <tr>
	     <td align="right">网站数量：</td>
	     <td><span class="table_txt"><input type="text" name="webnum" value="{$data.webnum}" lay-verify="" class="layui-input" style="width:50px;"></span>
            <span class="table_txt"><font color="#666666">（自动更新）</font></span></td>
        </tr>
    <tr>
    <tr>
	     <td align="right">对应备案：</td>
	     <td><span class="table_txt"><input type="text" name="beian" value="{$data.beian}" lay-verify="" class="layui-input" ></span>
            <span class="table_txt"></span></td>
        </tr>
    <tr>
	  <td align="right">分组描述：</td>
	  <td><span class="table_span" style="width:300px; float:left;"><textarea name="content" type="text" id="content" value=""  lay-verify="" placeholder="其他信息" autocomplete="off" class="layui-textarea" style="height:60px;">{$data.content}</textarea></span>
      </td>
    </tr>
    <tr>
	     <td align="right">排序：</td>
	     <td><span class="table_txt"><input type="text" name="listorder" value="{$data.listorder}" lay-verify="listorder" class="layui-input" style="width:50px;"></span>
            <span class="table_txt"><font color="#666666">（越大越靠前）</font></span></td>
        </tr>
	   <td align="right"><font color=red size="1">·</font>添加时间：</td>
	  <td><input name="inputtime" type="text" id="inputtime" value="{$data.inputtime|date='Y-m-d H:i:s',###}"  autocomplete="off" class="layui-input ico-date"  style="width:250px; float:left;"></td>
	  </tr>
    <tr> 
	  <td colspan=2 align="center" valign="middle">
		<input type="submit" name="Submit" value="确&nbsp; &nbsp;定" class="layui-btn" >
		<input type="reset" name="Submit2" value="重　置" class="layui-btn layui-btn-primary" >		 </td>
	</tr>
    </table>
</div>
</form>
</div>
<script type="text/javascript" src="__PUBLIC__/js/common.js"></script>
</body>
</html>
<script>

//Demo
layui.use(['form','laydate'], function(){
  var form = layui.form
  ,laydate = layui.laydate;
   //,layer = layui.layer	
   
   form.verify({
        groupname: function(value){
		    if(value !="" || value.length  >0){
			    
			}else{
			   return '请填写分组名称';
			}
		}   
	   ,listorder: function(value){
	       if(value != ""){
			   if(!new RegExp(/^\d*$/).test(value)){
		            return '必须是数字0';
		       }
		   }
	   }
   });
   
   laydate.render({
       elem:'#inputtime'
	   ,type:'datetime'
   });
   
  //监听提交
  form.on('submit(formSearch)', function(data){
    //layer.msg(JSON.stringify(data.field));
	title: '最终的提交信息'
	return true;
  });

});

</script>